<?php
// +----------------------------------------------------------------------
// | 后台用户管理
// +----------------------------------------------------------------------
namespace app\common\model;
use think\Model;

class MsgContent extends Model
{
	use \base\model\ModelTrait;
    
	/**
    * 自动添加uniques
    * @return type
    */
    protected $auto= ['uniques'];  
	public function setUniquesAttr($val,$data)
    {
		$uniques = [(String)$data['recive_id'],(String)$data['send_id']]; sort($uniques); 
		return $val ?: md5(join(",",$uniques));
    }
	
}
